package com.hengpeng.msls.controller;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.hengpeng.common.exception.ServiceResult;
import com.hengpeng.common.persist.QueryResult;
import com.hengpeng.msls.util.CommUtil;

@Controller
public class IndexController extends BaseController
{
	// 首页轮播广告
	private final static String INDEX_NEWS_GROUPID = "index.news.groupId";

	// 首页资讯列表
	private final static String INDEX_NEWSLIST_GROUPID = "index.newslist.groupId";

	// 首页底部图片资讯列表
	private final static String INDEX_IMAGENEWSLIST_GROUPID = "index.imagenewslist.groupId";

	// 购彩大厅首页玩法排序
	public final static String android_Client_GameRank_HuaShu = "GameRank_HuaShu";


	@RequestMapping(value = "/index")
	public String index(HttpServletRequest request, ModelMap map)
	{
		return "";
	}

	@RequestMapping(value = "/buylottery")
	public String buylottery(HttpServletRequest request, ModelMap map)
	{
		
		return "/page/index/ccb/index.jsp";
	}

	/**
	 * <pre>
	 * 根据会员店查询首页资讯列表
	 * </pre>
	 * @param request
	 * @param map
	 * @return
	 */
	@RequestMapping(value = "/indexNews")
	public String indexNews(HttpServletRequest request, ModelMap map, String url, Integer size, Long logoGroupId)
	{
		return "";
	}

	@RequestMapping(value = "/indexNewsBody")
	@ResponseBody
	public ServiceResult<Object> indexNewsBody(HttpServletRequest request, ModelMap map, Integer currentPages,
			Integer pageSizes, Long logoGroupId)
	{
		// 默认首页
		
		ServiceResult<Object> retult = new ServiceResult<Object>();
		retult.setReturnValue(null);
		retult.setReturnObject(currentPages);
		return retult;
	}

	@RequestMapping(value = "/about")
	public String about(HttpServletRequest request, ModelMap map)
	{
		return "/page/wasu/description/about.jsp";
	}

	@RequestMapping(value = "/setBuy")
	public String setBuy(HttpServletRequest request, ModelMap map)
	{
		return "/page/wasu/description/setBuy.jsp";
	}

	@RequestMapping(value = "/getpwd")
	public String getpwd(HttpServletRequest request, ModelMap map)
	{
		return "/page/wasu/description/zhmm.jsp";
	}

	@RequestMapping(value = "/toRegister")
	public String toRegister(HttpServletRequest request, ModelMap map)
	{
		return "/page/wasu/mylottery/register.jsp";
	}

	@RequestMapping(value = "/toLogin")
	public String toLogin(HttpServletRequest request, ModelMap map)
	{
		return "/page/wasu/mylottery/login.jsp";
	}

	@RequestMapping(value = "/to306Login")
	public String to306Login(HttpServletRequest request, ModelMap map)
	{
		map.put("is306", "YES");
		return "/page/wasu/mylottery/login.jsp";
	}
}
